import Interface.Person;
import Interface.Student;

public class Demo03 {

    public static void main(String[] args) {
        Person person = new Person();
        person.show();

        /*----封装-------*/
        person.name = "赵丽颖";   //未私有化
        person.setAge(20);  //私有化
        person.show();

        /*----this.用法-------*/
        person.name = "王健林";
        person.sayHello("王思聪");


        /*---构造方法示例-------*/
        Student stu1 = new Student(); // 无参构造
        System.out.println("============");

        Student stu2 = new Student("赵丽颖", 20); // 全参构造
        System.out.println("姓名：" + stu2.getName() + "，年龄：" + stu2.getAge());




    }

}
